<template>
  <div>
    <button ref="buttonEl">wo de tian</button>
  </div>
</template>

<script lang="ts" setup>
import { ref, onMounted } from "vue";

const buttonEl = ref<HTMLButtonElement>();

onMounted(() => {
  buttonEl.value; // button DOM对象

  buttonEl.value?.innerHTML;
});
</script>
